x86/nospec: Unwreck the RSB stuffing
Origin: https://lore.kernel.org/stable/
3e14d81d0576aed9583d07fbd14e6a502f2d4739.camel@decadent.org.uk/
commit
4e3aa9238277597c6c7624f302d81a7b568b6f2d upstream.
Commit
2b1299322016 ("x86/speculation: Add RSB VM Exit protections")
made a right mess of the RSB stuffing, rewrite the whole thing to not
suck.
Thanks to Andrew for the enlightening comment about Post-Barrier RSB
things so we can make this code less magical.
Cc: stable@vger.kernel.org
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lkml.kernel.org/r/YvuNdDWoUZSBjYcm@worktop.programming.kicks-ass.net
[bwh: Backported to 5.10: adjust context]
Signed-off-by: Ben Hutchings <benh@debian.org>
Gbp-Pq: Topic bugfix/x86
Gbp-Pq: Name x86-nospec-Unwreck-the-RSB-stuffing.patch